package com.tjetc.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.tjetc.entity.User;
import com.tjetc.mapper.UserMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

/**
 * @author gaoyongxiang
 * @version v1.0
 * @since 2025-10-11
 */
@Slf4j
@Service
public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements UserService {


    public void f1(User user){
        // 我们的日志将来会打印在linux 服务器上没有办法使用debug
        log.info("UserServiceImpl.f1进入， 参数是: {}", user);

        // 调用其他的层 或者是想查看关键参数
        // 判断是否开启debug 提高效率
        if (log.isDebugEnabled()) {
            log.debug("User: {} ", user);
        }

        try {
            // ......
        }catch (Exception e) {
            log.error("异常类型， 异常信息 {}", e.getMessage());
        }



        log.info("UserServiceImpl.f1退出");
    }

}
